package com.tjrac.generalpermissions.service;

import com.tjrac.generalpermissions.domain.Role;
import com.tjrac.generalpermissions.domain.User;
import com.tjrac.generalpermissions.epception.MsgException;

/**
 * @author ZeNing
 * @create 2020-12-01 15:46
 */
public interface UserManagementService {

    /**
     * 根据用户id查找当前用户
     */
    User queryById(int id) throws MsgException;

    /**
     * 根据用户username查找当前用户
     */
    User queryByUsername(String username) throws MsgException;

    /**
     * 查找所有用户
     */
    String queryAllUser() throws MsgException;

    /**
     * 添加用户
     */
    String addUser(User user) throws MsgException;

    /**
     * 删除用户
     */
    String delUser(int id) throws MsgException;

    /**
     * 修改用户
     */
    String modifyUser(User user) throws MsgException;

}
